package model.filtros;

import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;

import org.junit.Test;

public class MontoHastaTest extends FiltrosDeBusquedaTest {
	
	@Test
	public void testMontoDesdeCoincide() {
		when(prestamoMock.getMontoPedido()).thenReturn(10000.0);
		assertTrue(new MontoHasta(15000.0).coincide(prestamoMock));
		verify(prestamoMock).getMontoPedido();
	}
		
	@Test
	public void testMontoDesdeNoCoincide() {
		when(prestamoMock.getMontoPedido()).thenReturn(30000.0);
		assertFalse(new MontoHasta(25000.0).coincide(prestamoMock));
		verify(prestamoMock).getMontoPedido();
	}

}
